package edu.nbut.hotel.model.entity.javafxbean;

import edu.nbut.hotel.model.enums.RoomStatus;
import javafx.beans.property.DoubleProperty;
import javafx.beans.property.SimpleDoubleProperty;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.StringProperty;

public class Room {
    private StringProperty number;
    private StringProperty type;
    private DoubleProperty price;
    private StringProperty status;
    private DoubleProperty pledge;
    private StringProperty other;

    public Room() {
    }

    public Room(edu.nbut.hotel.model.entity.pojo.Room room){
        number = new SimpleStringProperty(room.getNumber());
        type = new SimpleStringProperty(room.getType());
        price = new SimpleDoubleProperty(room.getPrice());
        status = new SimpleStringProperty(room.getStatus().value);
        pledge = new SimpleDoubleProperty(room.getPledge());
        other = new SimpleStringProperty(room.getOther());
    }

    public String getNumber() {
        return number.get();
    }

    public StringProperty numberProperty() {
        return number;
    }

    public void setNumber(String number) {
        this.number.set(number);
    }

    public String getType() {
        return type.get();
    }

    public StringProperty typeProperty() {
        return type;
    }

    public void setType(String type) {
        this.type.set(type);
    }

    public double getPrice() {
        return price.get();
    }

    public DoubleProperty priceProperty() {
        return price;
    }

    public void setPrice(double price) {
        this.price.set(price);
    }

    public String getStatus() {
        return status.get();
    }

    public StringProperty statusProperty() {
        return status;
    }

    public void setStatus(String status) {
        this.status.set(status);
    }

    public double getPledge() {
        return pledge.get();
    }

    public DoubleProperty pledgeProperty() {
        return pledge;
    }

    public void setPledge(double pledge) {
        this.pledge.set(pledge);
    }

    public String getOther() {
        return other.get();
    }

    public StringProperty otherProperty() {
        return other;
    }

    public void setOther(String other) {
        this.other.set(other);
    }
}
